const WebSocket = require('ws');

const wss = new WebSocket.Server({ port: 8082 });

wss.on('connection', ws => {
  ws.on('message', message => {
    wss.clients.forEach(client => {
        if (client.readyState === WebSocket.OPEN) {
          client.send(`${message}`);
        }
      });
  });

  ws.send('1,3');
});